package com.kazarus.examplx00005;

import android.app.Activity;
import android.os.Bundle;
import android.view.KeyEvent;  
import android.webkit.WebView;  

public class examplx00005 extends Activity 
{
	private WebView webview;  
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) 
    {
    	super.onCreate(savedInstanceState);
        
        webview = new WebView(this);  
       
        webview.getSettings().setJavaScriptEnabled(true);  
        
        webview.loadUrl("http://www.cnblogs.com/hibraincol/");  
        
        setContentView(webview);     	
    }
    
    @Override 
    
    
    public boolean onKeyDown(int keyCode, KeyEvent event) 
    {  
        if ((keyCode == KeyEvent.KEYCODE_BACK) && webview.canGoBack()) 
        {  
            webview.goBack(); 
            return true;  
        }  
        return false;     
    }    
    
    
        
}